@mixin menu-styles($background){
  >li>a {

    &:hover,
    &:focus {
      color: #fff;
      background-color: $background;
    }
  }
}

.dropdown-menu {
  background-color: $dropdown-bg;
  border: 1px solid $dropdown-fallback-border; // IE8 fallback
  border: 1px solid $dropdown-border;
  .divider {
    @include nav-divider($dropdown-divider-bg);
  }
  >li>a {
    color: $dropdown-link-color;
    &:hover,
    &:focus {
      color: $dropdown-link-hover-color;
      text-decoration: none;
      background-color: $dropdown-link-hover-bg;
    }
  }

  &.dropdown-menu-primary {
    @include menu-styles($btn-primary-bg);
  }
  &.dropdown-menu-success {
    @include menu-styles($btn-success-bg);
  }
  &.dropdown-menu-info {
    @include menu-styles($btn-info-bg);
  }
  &.dropdown-menu-warning {
    @include menu-styles($btn-warning-bg);
  }
  &.dropdown-menu-danger {
    @include menu-styles($btn-danger-bg);
  }

}
.dropdown-menu>.active>a {

  &,
  &:hover,
  &:focus {
    color: $dropdown-link-active-color;
    text-decoration: none;
    background-color: $dropdown-link-active-bg;
    outline: 0;
  }
}

.dropdown-menu>.disabled>a {
  &,
  &:hover,
  &:focus {
    color: rgba($color: $gray-light, $alpha: 0.6);
  }
  &:hover,
  &:focus {
    background-color: transparent;
    background-image: none; // Remove CSS gradient
  }
}

.dropdown-header {
  color: $dropdown-header-color;
}